from django_filters import rest_framework as filters
from apps.articles.models import Article


class ArticleFilter(filters.FilterSet):
    ordering = filters.OrderingFilter(fields=('clicks', 'create_time'))

    class Meta:
        model = Article
        fields = ['category']
